<!DOCTYPE html>
<html lang="en">
<head>
    <!-- Required meta tags -->
    <meta charset="utf-8">
    <meta name="viewport" content="width=device-width, initial-scale=1, shrink-to-fit=no">
    <!-- 框架头 -->
    <script language="JavaScript" src="../FrontFrame/head.js"></script>
    <link rel="stylesheet" type="text/css" href="../css/equipment.css">
    <script language="JavaScript" src="../js/equipment.js"></script>
    <title>设备管理</title>
</head>
<body style='overflow:scroll;overflow-y:hidden'>
<!-- 新闻修改的模态框 -->
<div class="modal fade" id="equipmentUpdateModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title">设备修改</h4>
            </div>
            <div class="modal-body">
                <form class="form-horizontal">
                    <div class="form-group">
                        <label class="col-sm-2 control-label"></label>
                        <div class="col-sm-9">
                            <input type="text" name="equipmentId" class="form-control" id="id_update_input" placeholder="设备ID" style="display: none">
                            <span class="help-block"></span>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label">设&nbsp;&nbsp;备&nbsp;&nbsp;名</label>
                        <div class="col-sm-9">
                            <input type="text" name="equipmentName" class="form-control" id="equipmentName_update_input" placeholder="设备名">
                            <span class="help-block"></span>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label">设备状态</label>
                        <div class="col-sm-4">
                            <!-- 部门提交部门id即可 -->
                            <select class="form-control" id="upEquipmentState" name="equipmentState"  >
                                <!--<option value="1">未连接</option>-->
                                <!--<option value="2">已连接</option>-->
                                <!--<option value="3">其他异常</option>-->
                            </select>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label">设&nbsp;&nbsp;备&nbsp;&nbsp;IP</label>
                        <div class="col-sm-9">
                            <input type="text" name="equipmentIp" class="form-control" id="equipmentIP_update_input" placeholder="设备名">
                            <span class="help-block"></span>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label"></label>
                        <div class="col-sm-9">
                            <input type="text" name="standby1" class="form-control" id="standby1_update_input" VALUE="1" readonly="readonly" style="display: none">
                            <span class="help-block"></span>
                        </div>
                    </div>

                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                <button type="button" class="btn btn-primary" id="equipment_update_btn">更新</button>
            </div>
        </div>
    </div>
</div>



<!-- 设备添加的模态框 -->
<div class="modal fade" id="equipmentAddModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
    <div class="modal-dialog" role="document">
        <div class="modal-content">
            <div class="modal-header">
                <button type="button" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span></button>
                <h4 class="modal-title" id="myModalLabel">设备添加</h4>
            </div>
            <div class="modal-body">
                <form class="form-horizontal">
                    <div class="form-group">
                        <label class="col-sm-2 control-label"></label>
                        <div class="col-sm-9">
                            <input type="text" name="equipmentId" class="form-control" id="id_add_input" placeholder="设备ID" style="display: none">
                            <span class="help-block"></span>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label">设&nbsp;&nbsp;备&nbsp;&nbsp;名</label>
                        <div class="col-sm-9">
                            <input type="text" name="equipmentName" class="form-control" id="equipmentName_add_input" placeholder="设备名">
                            <span class="help-block"></span>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label">设备状态</label>
                        <div class="col-sm-4">
                            <select class="form-control" name="equipmentState">
                                <option value="1">未连接</option>
                                <option value="2">已连接</option>
                                <option value="3">其他异常</option>
                            </select>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label">设&nbsp;&nbsp;备&nbsp;&nbsp;IP</label>
                        <div class="col-sm-9">
                            <input type="text" name="equipmentIp" class="form-control" id="equipmentIP_add_input" placeholder="设备名">
                            <span class="help-block"></span>
                        </div>
                    </div>
                    <div class="form-group">
                        <label class="col-sm-2 control-label"></label>
                        <div class="col-sm-9">
                            <input type="text" name="standby1" class="form-control" id="standby1_add_input" VALUE="1" readonly="readonly" style="display: none">
                            <span class="help-block"></span>
                        </div>
                    </div>

                </form>
            </div>
            <div class="modal-footer">
                <button type="button" class="btn btn-default" data-dismiss="modal">关闭</button>
                <button type="button" class="btn btn-primary" id="equipment_save_btn">保存</button>
            </div>
        </div>
    </div>
</div>

<!-- 搭建显示页面 -->
<div class="container">
    <div class="row">
        <div class="col-md-1"id="f">
                <div > <button class="btn btn-info" id="equipment_add_modal_btn"> 添加</button> </div>
        </div>
        <!-- 按钮搜索设备发布内容-->
        <div class="col-md-4">
            <div class="input-group">
                <input type="text" class="form-control" placeholder="查找名字" id="name">
                <span class="input-group-btn">
                <button class="btn btn-info"  type="button" onclick="find();" >查找</button>
                </span>
            </div>
        </div>
        <div class="col-md-5 col-md-offset-2">
                <label>运行状态</label>
                <select id="state" style="width: 120px;height: 24px">
                    <option  selected = "selected"  value="4">--请选择--</option>
                    <option value="1">未连接</option>
                    <option value="2">已连接</option>
                    <option value="3">其他异常</option>
                </select>
        </div>
    </div>
    <hr class="row">
    <!-- 显示表格数据 -->
    <div class="row">
        <div class="col-md-12">
            <table class="table table-hover" id="equipment_table">
                <thead>
                <tr>
                    <td>
                        <!--  <input type="checkbox" id="check_all"/>-->
                    </td>
                    <td>设备ID</td>
                    <td>设备名</td>
                    <td>设备运行状态</td>
                    <td>设备IP</td>
                    <td>操作</td>
                </tr>
                </thead>
                <tbody></tbody>
            </table>
        </div>
    </div>
    <!-- 显示分页信息 -->
    <div class="row">
        <!--分页文字信息  -->
        <div class="col-md-6" id="page_info_area"></div>
        <!-- 分页条信息 -->
        <div class="col-md-6" id="page_nav_area">

        </div>
    </div>
</div>
</body>
</html>